package com.mmsj;

import android.content.Intent;
import android.os.Bundle;
import android.widget.TextView;

import androidx.activity.EdgeToEdge;
import androidx.appcompat.app.AppCompatActivity;


public class HomeActivity extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        EdgeToEdge.enable(this);
        setContentView(R.layout.activity_home);
        // 解析意图数据
        Intent intent = getIntent();
        Bundle bundle = intent.getExtras();
        assert bundle != null;
        String username = bundle.getString("username");
        String password = bundle.getString("password");
//        获取控件
        TextView textView = findViewById(R.id.tv_name);
        textView.setText(username);

    }
}